package com.cgbl.cg.vm.mine

import android.app.Application
import androidx.databinding.ObservableInt
import com.robot.base.base.vm.GLBaseViewModel
import com.robot.base.configs.AppConstants
import com.robot.base.util.arouter.ARouterUtil
import me.goldze.mvvmhabit.binding.command.BindingAction
import me.goldze.mvvmhabit.binding.command.BindingCommand

class FeedbackViewModel(application: Application) : GLBaseViewModel(application) {

    val clickModifyAccountCommand = BindingCommand<Any>(BindingAction {
        ARouterUtil.goToActivity(AppConstants.Router.Mine.A_MINE_MODIFY_ACCOUNT)
    })

    val tabType = ObservableInt(TAB_SUGGEST)

    val clickSelectSuggest = BindingCommand<Any>(BindingAction {
        tabType.set(TAB_SUGGEST)
    })

    val clickSelectQuestion = BindingCommand<Any>(BindingAction {
        tabType.set(TAB_QUESTION)
    })

    val clickSelectOther = BindingCommand<Any>(BindingAction {
        tabType.set(TAB_OTHER)
    })

    companion object{

        const val TAB_SUGGEST = 1

        const val TAB_QUESTION = 2

        const val TAB_OTHER = 3

    }
}